//
    create by zhouquan
-var socialShare = ['sina', 'weixin', 'qq', 'renren'];
-var navList = [{href : '#', text: '欢迎'}, {href : '#', text: '介绍'}, {href : 'about', text: '团队'}, {href : '#', text: '帮助'}];
doctype html
html
    head 
        title= pageTitle ? pageTitle : 'PeerToPeer'
        link(rel="shortcut icon", href="/images/favicon.ico")
        link(type="text/css" rel="stylesheet" href="/css/reset.css")
        link(type="text/css" rel="stylesheet" href="/css/login.css")
        script(src="/lib/jquery-1.9.1.min.js")
        script(src="/lib/base.js")
        script(src="/js/login.js")
    body
        div.wallpaper
        div.h100.lg-container
            div.mid-wrap.wel-lg
                div.mid-bd.wel-lg
                    div
                        p Welcome to <span class="red">PeerToPeer</span>
                        div.sub-title You Can Share The Movies Face-to-face With Others In Here
                    div.lg-btn-wrap
                        div#loginBtn.lg-btn.fl.ml20(modal='#loginModal') 登&nbsp;&nbsp;&nbsp;&nbsp;陆
                        div#regBtn.lg-btn.fl.ml20(modal='#regModal') 注&nbsp;&nbsp;&nbsp;&nbsp;册
                        div.clear
            div.fixed.lg-nav-bot
                div.fl.lg-contact
                    div.fl.relative.lg-logo-container
                        div.mid-wrap.lg-logo-size
                            div.mid-bd.lg-logo-size.lg-bg-div
                    .clear
                div.fr.lg-nav
                    ul.lg-nav-ul.fr
                        each  val in navList
                            li: a(href = val.href)= val.text
                .clear

        // model Dialog DOM
        mixin modelDilog(id)
            div(id = id, style={display: 'none'})
                span.top-right-close.hidemodal &times;
                if block
                        block
                else
                    p No content provided

        +modelDilog('loginModal')
            .login-form-top
                span.weiruanYH.aaa 登陆到
                span.TektonPro.red PeerToPeer
            form#loginForm.bs-example.bs-example-form(method='post', action='/index')
                .login-input.login-input-email
                    label(for='loginEmail')
                        img(src='/images/login/evenlope.png')
                    input#loginEmail(type='text' name='loginEmail' autocomplete='off' input-data-default='请输入您的电子邮件')
                    span.input-right.login-email-tip
                .login-input.login-input-psw
                    label(for='loginPsw')
                        img(src='/images/login/lock.png')
                    input#loginPsw(type='password' name='loginPsw' autocomplete='off' input-data-default='请输入密码')
                .login-2btn
                    input.btn-160x50.login-left-btn(type='submit' value!='登&nbsp;&nbsp;陆')
                    input#goreg.btn-160x50.login-right-btn(type='button' value!='注&nbsp;&nbsp;册' modal='#regModal')

        +modelDilog('regModal')
            .login-form-top
                span.weiruanYH.aaa 欢迎注册
                span.TektonPro.red PeerToPeer
            form#regForm.bs-example.bs-example-form(method='post')
                .login-input.reg-input-email
                    label(for='regEmail')
                        img(src='/images/login/evenlope.png')
                    input#regEmail(type='text' name='regEmail' autocomplete='off' input-data-default='请输入您常用的电子邮件')
                    span.input-right.reg-email-tip1
                .login-input.reg-confirm-email
                    label(for='regConfirmEmail')
                        img(src='/images/login/evenlope.png')
                    input#regConfirmEmail(type='text' name='regConfirmEmail' autocomplete='off' input-data-default='请再次输入')
                    span.input-right.reg-email-tip2
                .login-input.reg-input-psw
                    label(for='regPsw')
                        img(src='/images/login/lock.png')
                    input#regPsw(type='password' name='regPsw' autocomplete='off' input-data-default='请输入密码（密码长度至少为6位）')
                    span.input-right.reg-psw-tip
                .reg-checkCode-wrap
                    .reg-input-checkCode
                        input#checkCode(type='text' name='checkCode' autocomplete='off' input-data-default='请输入验证码')
                        img.reg-checkCode(src='login/getcaption')
                .reg-btn-wrap
                    input.weiruanYH(type='submit' value='立即注册')
                .reg-login-btn
                    .reg-login-center
                        label.weiruanYH.aaa(for='gologin') 已有账号？
                        input#gologin.weiruanYH(name='gologin' type='button' value='现在登录' modal='#loginModal')
        script.
            $('#loginBtn').leanModal({top:110,overlay:0.45,closeButton:".hidemodal"});
            $("#regBtn").leanModal({top:110,overlay:0.45,closeButton:".hidemodal",callback:refreshCheckCode});
            $("#goreg").leanModal({top:110,overlay:0.45,closeButton:".hidemodal",callback:refreshCheckCode});
            $("#gologin").leanModal({top:110,overlay:0.45,closeButton:".hidemodal"});